KF Tool v2 November 2017

A simple tool for use with the PS1 games in the King's Field series. It does 2 things:

1. Enables editing of text graphics. Most dialog in the King's Field games is stored in TIM graphics, but the game includes a tamper protection that locks-up the game if a TIM's checksum has changed (aka it has been edited). This tool changes a CD image to allow the text-graphics to be edited. It should help if someone wants to do a translation.

2. Extracts / inserts most non-TIM textures from the King's Field games. Some pop-up message text is also stored in this format. This would allow you to do pop-up translation, or re-skin the game's 3D models.

NOTES:
The extract feature will not work on a whole disk image because the graphics will be broken up by the CD's sector data. Most testures are in the FDAT.T file.

If you extract a graphic, don't change its name if you plan on reinserting it. The tool uses the name to decide where, and into which file to re-insert. 

The tool only scans for a specific type of square 4BPP graphics which are used for 99% of the textures in KF1 and 2. It won't extract other types of graphics such as the standard TIMs used for dialog text.

It extracts corrupted copies of rectangular graphics. There are only a few of these in the KF games and I don't think they are backgrounds, not textures. 

It won't work to reinsert a TIM if you have changed its BPP or size of course.